<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
	<th:block th:include="include :: header('新增元数据')" />
</head>
<body class="white-bg">
    <div class="wrapper wrapper-content animated fadeInRight ibox-content">
        <form class="form-horizontal m" id="form-metadata-add">
        	<input type="hidden" name="token" th:value="${session.token}"/>
			<div class="form-group">	
				<label class="col-sm-2 control-label">元数据名称：</label>
				<div class="col-sm-10">
					<input id="columnName" name="columnName" class="form-control" type="text" placeholder="请输入元数据名称" required>
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-2 control-label">元数据类型：</label>
				<div class="col-sm-10">
					<select name="columnType" class="form-control m-b">
						<option value="">请选择元数据类型</option>
					    <option value="String">字符串 例abcABC123</option>
					    <option value="Integer">整数 例-2^31 ~ 2^31 - 1</option>
					    <option value="Long">长整数 例-2^63 ~ -2^63 - 1</option>
					    <option value="Double">浮点数 例2^-1024 ~ 2^1024 - 1</option>
					    <option value="Date">时间 例：2020-05-15 12:50:20</option>
	                </select>
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-2 control-label">元数据描述：</label>
				<div class="col-sm-10">
					<input id="columnComment" name="columnComment" class="form-control" type="text" placeholder="请输入元数据描述">
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-2 control-label">备注：</label>
				<div class="col-sm-10">
					<input id="remark" name="remark" class="form-control" type="text" placeholder="请输入备注">
				</div>
			</div>
		</form>
	</div>
    <th:block th:include="include :: footer" />
    <script type="text/javascript">
        var prefix = ctx + "devtool/metadata";
		
		function submitHandler() {
	        if ($.validate.form()) {
				$.operate.save(prefix + "/add", $('#form-metadata-add').serialize());
	        }
	    }
	</script>
</body>
</html>
